package com.suse.lhw.resourceservere.client;


import com.suse.lhw.resourceservere.domin.PHealthData;
import com.suse.lhw.resourceservere.domin.PHealthrecord;
import com.suse.lhw.resourceservere.domin.PIfo;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.Date;

/**
 * @ProjectName: health_manage_system
 * @Package: com.suse.lhw.resourceservere.client
 * @ClassName: personserverClient
 * @Description: java类作用描述
 * @Author: 李鸿炜
 * @CreateDate: 2020/4/15 9:09
 * @UpdateUser: 更新者
 * @UpdateDate: 2020/4/15 9:09
 * @UpdateRemark: 更新说明
 * @Version: 1.0
 */
@FeignClient("PERSONSERVER")
public interface personserverClient {
    @GetMapping("test/sayhello")
    public String saysheelo();

    @PostMapping("personUser/addPersonIfo")
    public String addPersonIfo(PIfo pIfo);

    @PostMapping("personUser/updatePersonIfo")
    public String updatePersonIfo(PIfo pIfo);

    @PostMapping("personUser/selectPifoByUserid")
    public PIfo selectPifoByUserId(String userId);

    @PostMapping("personUser/addAhealthdata")
    public String addAHealthData(PHealthData pHealthData);

    @PostMapping("personUser/updateAHealthData")
    public String updateAHealthData(PHealthData pHealthData);

    @PostMapping("personUser/selectAHealthData")
    public PHealthData selectAHealthData();

    @RequestMapping("personUser/selectAHealthRecord")
    public PHealthrecord selectAHealthRecord(@RequestParam int totalFoodCalories, @RequestParam int totalMovementCalories);

    @RequestMapping("personUser/isHRecordExit")
    public boolean isHRecordExit();
}


